Optimal. Leaf size=183 \[ \frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {2 b e^2 \log \left (\frac {2}{1+i (c+d x)}\right ) \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i b^2 e^2 \text {Li}_2\left (1-\frac {2}{i (c+d x)+1}\right )}{3 d}-\frac {b^2 e^2 \tan ^{-1}(c+d x)}{3 d}+\frac {1}{3} b^2 e^2 x \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.22, antiderivative size = 183, normalized size of antiderivative = 1.00, number of steps used = 11, number of rules used = 10, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.435, Rules used = {5043, 12, 4852, 4916, 321, 203, 4920, 4854, 2402, 2315} \[ -\frac {i b^2 e^2 \text {PolyLog}\left (2,1-\frac {2}{1+i (c+d x)}\right )}{3 d}+\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {2 b e^2 \log \left (\frac {2}{1+i (c+d x)}\right ) \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {b^2 e^2 \tan ^{-1}(c+d x)}{3 d}+\frac {1}{3} b^2 e^2 x \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 203
Rule 321
Rule 2315
Rule 2402
Rule 4852
Rule 4854
Rule 4916
Rule 4920
Rule 5043
Rubi steps
\begin {align*} \int (c e+d e x)^2 \left (a+b \tan ^{-1}(c+d x)\right )^2 \, dx &=\frac {\operatorname {Subst}\left (\int e^2 x^2 \left (a+b \tan ^{-1}(x)\right )^2 \, dx,x,c+d x\right )}{d}\\ &=\frac {e^2 \operatorname {Subst}\left (\int x^2 \left (a+b \tan ^{-1}(x)\right )^2 \, dx,x,c+d x\right )}{d}\\ &=\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {\left (2 b e^2\right ) \operatorname {Subst}\left (\int \frac {x^3 \left (a+b \tan ^{-1}(x)\right )}{1+x^2} \, dx,x,c+d x\right )}{3 d}\\ &=\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {\left (2 b e^2\right ) \operatorname {Subst}\left (\int x \left (a+b \tan ^{-1}(x)\right ) \, dx,x,c+d x\right )}{3 d}+\frac {\left (2 b e^2\right ) \operatorname {Subst}\left (\int \frac {x \left (a+b \tan ^{-1}(x)\right )}{1+x^2} \, dx,x,c+d x\right )}{3 d}\\ &=-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}+\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {\left (2 b e^2\right ) \operatorname {Subst}\left (\int \frac {a+b \tan ^{-1}(x)}{i-x} \, dx,x,c+d x\right )}{3 d}+\frac {\left (b^2 e^2\right ) \operatorname {Subst}\left (\int \frac {x^2}{1+x^2} \, dx,x,c+d x\right )}{3 d}\\ &=\frac {1}{3} b^2 e^2 x-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}+\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {2 b e^2 \left (a+b \tan ^{-1}(c+d x)\right ) \log \left (\frac {2}{1+i (c+d x)}\right )}{3 d}-\frac {\left (b^2 e^2\right ) \operatorname {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,c+d x\right )}{3 d}+\frac {\left (2 b^2 e^2\right ) \operatorname {Subst}\left (\int \frac {\log \left (\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{3 d}\\ &=\frac {1}{3} b^2 e^2 x-\frac {b^2 e^2 \tan ^{-1}(c+d x)}{3 d}-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}+\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {2 b e^2 \left (a+b \tan ^{-1}(c+d x)\right ) \log \left (\frac {2}{1+i (c+d x)}\right )}{3 d}-\frac {\left (2 i b^2 e^2\right ) \operatorname {Subst}\left (\int \frac {\log (2 x)}{1-2 x} \, dx,x,\frac {1}{1+i (c+d x)}\right )}{3 d}\\ &=\frac {1}{3} b^2 e^2 x-\frac {b^2 e^2 \tan ^{-1}(c+d x)}{3 d}-\frac {b e^2 (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{3 d}-\frac {i e^2 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}+\frac {e^2 (c+d x)^3 \left (a+b \tan ^{-1}(c+d x)\right )^2}{3 d}-\frac {2 b e^2 \left (a+b \tan ^{-1}(c+d x)\right ) \log \left (\frac {2}{1+i (c+d x)}\right )}{3 d}-\frac {i b^2 e^2 \text {Li}_2\left (1-\frac {2}{1+i (c+d x)}\right )}{3 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.43, size = 163, normalized size = 0.89 \[ \frac {e^2 \left (a^2 (c+d x)^3+a b \left (-(c+d x)^2+\log \left ((c+d x)^2+1\right )+2 (c+d x)^3 \tan ^{-1}(c+d x)\right )+b^2 \left (i \text {Li}_2\left (-e^{2 i \tan ^{-1}(c+d x)}\right )+(c+d x)^3 \tan ^{-1}(c+d x)^2-(c+d x)^2 \tan ^{-1}(c+d x)+i \tan ^{-1}(c+d x)^2-\tan ^{-1}(c+d x)-2 \tan ^{-1}(c+d x) \log \left (1+e^{2 i \tan ^{-1}(c+d x)}\right )+c+d x\right )\right )}{3 d} \]
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
fricas [F] time = 0.67, size = 0, normalized size = 0.00 \[ {\rm integral}\left (a^{2} d^{2} e^{2} x^{2} + 2 \, a^{2} c d e^{2} x + a^{2} c^{2} e^{2} + {\left (b^{2} d^{2} e^{2} x^{2} + 2 \, b^{2} c d e^{2} x + b^{2} c^{2} e^{2}\right )} \arctan \left (d x + c\right )^{2} + 2 \, {\left (a b d^{2} e^{2} x^{2} + 2 \, a b c d e^{2} x + a b c^{2} e^{2}\right )} \arctan \left (d x + c\right ), x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \mathit {sage}_{0} x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.20, size = 593, normalized size = 3.24 \[ \frac {a^{2} c^{3} e^{2}}{3 d}+\frac {b^{2} c \,e^{2}}{3 d}+\arctan \left (d x +c \right )^{2} x \,b^{2} c^{2} e^{2}-\frac {d \,x^{2} a b \,e^{2}}{3}+d \,x^{2} a^{2} c \,e^{2}+\frac {\arctan \left (d x +c \right )^{2} b^{2} c^{3} e^{2}}{3 d}-\frac {\arctan \left (d x +c \right ) b^{2} c^{2} e^{2}}{3 d}+\frac {d^{2} \arctan \left (d x +c \right )^{2} x^{3} b^{2} e^{2}}{3}-\frac {d \arctan \left (d x +c \right ) x^{2} b^{2} e^{2}}{3}+\frac {e^{2} a b \ln \left (1+\left (d x +c \right )^{2}\right )}{3 d}+\frac {d^{2} x^{3} a^{2} e^{2}}{3}+x \,a^{2} c^{2} e^{2}+\frac {e^{2} b^{2} \arctan \left (d x +c \right ) \ln \left (1+\left (d x +c \right )^{2}\right )}{3 d}-\frac {2 \arctan \left (d x +c \right ) x \,b^{2} c \,e^{2}}{3}-\frac {2 x a b c \,e^{2}}{3}-\frac {i e^{2} b^{2} \ln \left (d x +c -i\right )^{2}}{12 d}+\frac {i e^{2} b^{2} \ln \left (d x +c +i\right )^{2}}{12 d}+\frac {i e^{2} b^{2} \dilog \left (\frac {i \left (d x +c -i\right )}{2}\right )}{6 d}-\frac {i e^{2} b^{2} \dilog \left (-\frac {i \left (d x +c +i\right )}{2}\right )}{6 d}-\frac {a b \,c^{2} e^{2}}{3 d}-\frac {b^{2} e^{2} \arctan \left (d x +c \right )}{3 d}+\frac {i e^{2} b^{2} \ln \left (d x +c +i\right ) \ln \left (\frac {i \left (d x +c -i\right )}{2}\right )}{6 d}+\frac {i e^{2} b^{2} \ln \left (d x +c -i\right ) \ln \left (1+\left (d x +c \right )^{2}\right )}{6 d}-\frac {i e^{2} b^{2} \ln \left (d x +c -i\right ) \ln \left (-\frac {i \left (d x +c +i\right )}{2}\right )}{6 d}-\frac {i e^{2} b^{2} \ln \left (d x +c +i\right ) \ln \left (1+\left (d x +c \right )^{2}\right )}{6 d}+\frac {2 \arctan \left (d x +c \right ) a b \,c^{3} e^{2}}{3 d}+\frac {2 d^{2} \arctan \left (d x +c \right ) x^{3} a b \,e^{2}}{3}+d \arctan \left (d x +c \right )^{2} x^{2} b^{2} c \,e^{2}+2 \arctan \left (d x +c \right ) x a b \,c^{2} e^{2}+2 d \arctan \left (d x +c \right ) x^{2} a b c \,e^{2}+\frac {b^{2} e^{2} x}{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \text {result too large to display} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.01 \[ \int {\left (c\,e+d\,e\,x\right )}^2\,{\left (a+b\,\mathrm {atan}\left (c+d\,x\right )\right )}^2 \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ e^{2} \left (\int a^{2} c^{2}\, dx + \int a^{2} d^{2} x^{2}\, dx + \int b^{2} c^{2} \operatorname {atan}^{2}{\left (c + d x \right )}\, dx + \int 2 a b c^{2} \operatorname {atan}{\left (c + d x \right )}\, dx + \int 2 a^{2} c d x\, dx + \int b^{2} d^{2} x^{2} \operatorname {atan}^{2}{\left (c + d x \right )}\, dx + \int 2 a b d^{2} x^{2} \operatorname {atan}{\left (c + d x \right )}\, dx + \int 2 b^{2} c d x \operatorname {atan}^{2}{\left (c + d x \right )}\, dx + \int 4 a b c d x \operatorname {atan}{\left (c + d x \right )}\, dx\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________